package priv.pront.code.lanqiao.competition.course.date0330;

import java.util.Scanner;

public class 耐摔指数 {
    static int n, left, right, count = 0, mid;
    static int[] dp;

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int[] x = new int[1000];
        int sum = 1;
        for (int i = 0; sum < n; i++) {
            sum = i + sum;
            x[i] = sum;
        }
        sum = 1;
        int k = 0;
        for (int i = 0; sum < n; i++) {
            sum = x[i] + sum;
            k++;
        }
        System.out.println(k);
    }

    private static void method() {
        dp = new int[n + 1];
        dp[3] = 2;
        dp[4] = 3;
        dp[5] = 3;
        for (int i = 6; i <= n; i++) {
            dp[i] = dp[i / 2] + 1;
        }
    }
}
